package com.yxjx.duoxue.course;

import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.ListView;

import com.yxjx.duoxue.BaseActionBarActivity;
import com.yxjx.duoxue.R;

public class SearchCityListActivity extends BaseActionBarActivity {
	
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.fragment_list);
		
		customizeSearchActionBar(R.layout.head_search_city);
		ListView mList = (ListView) findViewById(R.id.list);
		mList.setAdapter(new SearchCityListAdapter());
	}
	
	class SearchCityListAdapter extends BaseAdapter {

		@Override
		public int getCount() {
			return 4;
		}

		@Override
		public View getView(int arg0, View arg1, ViewGroup arg2) {
			View ret;
			if (arg1 == null) {
				ret = LayoutInflater.from(getApplicationContext()).inflate(R.layout.item_city_name, null);
			} else {
				ret = arg1;
			}
			return ret;
		}
		
		@Override
		public Object getItem(int arg0) {
			return null;
		}

		@Override
		public long getItemId(int arg0) {
			return 0;
		}


		
	}

}
